package com.example.test;

import lombok.Data;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;

/**
 * @ClassName User
 * @Description TODO
 * @Author H.
 * @Date 2023/4/23 19:59
 * @Version 1.0
 */
@Component
@Data
public class User {
    private String name;
    private int age;

    @Bean
    public User u1(){
        User user = new User();
        user.setName("李四");
        user.setAge(18);
        return user;
    }

}
